﻿$(document).ready(function () {
    $("#imgBuy").click(function () {
        var ProductId;
        var CateId;
        $('div .galleria-thumbnails').find('.galleria-image').each(function (id) {
            if ($(this).hasClass('active')) {
                var id_cate = $(".id-cate span").eq(id).text();
                var tmp = id_cate.split('_');
                ProductId = tmp[0];
                CateId = tmp[1];
            }
        });

        //var Pop = new Boxy($("#divpopip"), { title: "Detail", modal: true });
        $(".galleria-thumbnails div").each(function (index) {
            if ($(this).hasClass('active')) {
                alert(index);
            }
        });
        //alert($(".galleria-thumbnails").length);

    });

});

function boot() {
    if (!/*@cc_on!@*/0) return;
    var all = document.getElementsByTagName('*'), i = all.length;
    while (i--) {
        if (all[i].scrollWidth > all[i].offsetWidth) {
            all[i].style['paddingBottom'] = '32px';
            all[i].style['overflowY'] = 'hidden';
        }
    }
}